package main

import "fmt"

func main() {
	b := B{}
	b.A.name = "张三"
	b.sayHello()
}

type A struct {
	name string
	age  int
}

func (a *A) sayHello() {
	fmt.Println("你好，", a.name)
}

type B struct {
	name string
	A
}
